package com.infore.statisticsAndAlarm.controller.metaAnalysis;

import javax.servlet.http.HttpServletRequest;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.infore.statisticsAndAlarm.select.util.PageObject;
import com.infore.statisticsAndAlarm.service.IComparisonQualityService;
import com.infore.statisticsAndAlarm.util.ResultEntity;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

@Api(value = "综合分析---水质现状对比分析接口", tags = {"综合分析---水质现状对比分析接口" })
@RestController
@RequestMapping("/comparisonQuality")
public class ComparisonQualityController {

	@Autowired
	private IComparisonQualityService iComparisonQualityService;
	
	@ApiOperation(value="各因子监测值对比详情----表格（区域流域）")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/moreProjectDetailsReports")
	public ResultEntity moreProjectDetailsReports(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType ,HttpServletRequest request){
		return iComparisonQualityService.moreProjectDetailsReports(timeType,nativeTime,compareTime,
				queryCode,queryType, request);
	}
	
	@ApiOperation(value="各因子水质对比----柱状图")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/moreWaterQualityBars")
	public ResultEntity moreWaterQualityBars(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,HttpServletRequest request){
		return iComparisonQualityService.moreWaterQualityBars(timeType,nativeTime,compareTime,queryCode,
				queryType, request);
	}
	
	@ApiOperation(value="断面水质详情----饼图")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/moreWaterQualityPie")
	public ResultEntity moreWaterQualityPie(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,HttpServletRequest request){
		return iComparisonQualityService.moreWaterQualityPie(timeType,nativeTime,compareTime,queryCode,
				queryType, request);
	}
	
	@ApiOperation(value="各因子水质对比详情----柱状图（上下）")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/moreWaterQualityBarsUpDown")
	public ResultEntity moreWaterQualityBarsUpDown(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,HttpServletRequest request){
		return iComparisonQualityService.moreWaterQualityBarsUpDown(timeType,nativeTime,compareTime,queryCode,
				queryType, request);
	}
	
	@ApiOperation(value="各因子超标断面个数对比详情----表格个数对比")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/projectOverNumberReports")
	public ResultEntity projectOverNumberReports(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,HttpServletRequest request){
		return iComparisonQualityService.projectOverNumberReports(timeType,nativeTime,compareTime,queryCode,
				queryType, request);
	}
	
	@ApiOperation(value="各因子超标断面个数对比-----柱状图-个数对比")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/projectOverNumberBar")
	public ResultEntity projectOverNumberBar(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,HttpServletRequest request){
		return iComparisonQualityService.projectOverNumberBar(timeType,nativeTime,compareTime,queryCode,
				queryType, request);
	}
	
	@ApiOperation(value="各因子监测值对比详情----表格（站点）-----站点")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/moreProjectDetailsReportsMn")
	public ResultEntity moreProjectDetailsReportsMn(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,PageObject pageObject,HttpServletRequest request){
		return iComparisonQualityService.moreProjectDetailsReportsMn(timeType,nativeTime,compareTime,
				queryCode,queryType,pageObject, request);
	}
	
	@ApiOperation(value="水质对比 监测因子对比详情----表格----站点")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/projectReportsCompareMn")
	public ResultEntity projectReportsCompareMn(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,PageObject pageObject ,HttpServletRequest request){
		return iComparisonQualityService.projectReportsCompareMn(timeType,nativeTime,compareTime,
				queryCode,queryType,pageObject, request);
	}
	
	@ApiOperation(value="水质对比 监测因子对比详情----总结----站点")
	@ApiImplicitParams({@ApiImplicitParam(value = "时间类型", name = "timeType", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "本期时间", name = "nativeTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "对比时间", name = "compareTime", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询参数code", name = "queryCode", paramType = "query",required = true,dataType = "String"),
		@ApiImplicitParam(value = "查询类型-area区域/basinn流域station单站", name = "queryType", paramType = "query",required = true,dataType = "String")})
	@GetMapping(value = "/projectSummaryMn")
	public ResultEntity projectSummaryMn(String timeType,String nativeTime,String compareTime,
			String queryCode,String queryType,PageObject pageObject,HttpServletRequest request ){
		return iComparisonQualityService.projectSummaryMn(timeType,nativeTime,compareTime,queryCode,
				queryType,pageObject, request);
	}
}
